package com.yupi.springbootinit.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yupi.springbootinit.model.entity.ProcessSheetProduct;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;

/**
 * 工艺单产品明细 Mapper
 */
public interface ProcessSheetProductMapper extends BaseMapper<ProcessSheetProduct> {

    /**
     * 物理删除指定工艺单的所有产品明细
     */
    @Delete("DELETE FROM process_sheet_product WHERE process_sheet_id = #{processSheetId}")
    int physicalDeleteByProcessSheetId(@Param("processSheetId") Long processSheetId);
}